/**
 * Created by joy on 12/09/2017.
 */
import EthWalletHelper from '../../common/helpers/chain/EthWalletHelper'
import CommonUtil from '../../common/utils/CommonUtil'
import prompt from 'prompt'

export default async () => {
  const schema = {
    properties: {
      txHex: {
        description: 'Enter txHex',
        type: 'string',
        required: true
      },
    }
  }

  const args = await CommonUtil.getArgsFromConsole(prompt, schema)
  const { txHex } = args
  const ethWalletHelper = new EthWalletHelper()
  logger.info(ethWalletHelper.decodeTxHex(txHex))
}
